# Contributor: Will Sinatra <wpsinatra@gmail.com>
# Maintainer: Will Sinatra <wpsinatra@gmail.com>
pkgname=love
pkgver=11.3
pkgrel=0
pkgdesc="A Lua 2D Graphics Library"
url="https://love2d.org"
arch="x86_64 armv7 aarch64" #x86 disabled, pending mpg123-libs BAD signature fix
license="Zlib"
makedepends="libtool autoconf automake sdl2-dev zlib-dev openal-soft-dev
	freetype-dev libmodplug-dev mpg123-dev libvorbis-dev libtheora-dev luajit-dev
	lua-dev libx11-dev"
subpackages="$pkgname-doc"
source="love-$pkgver.tar.gz::https://bitbucket.org/rude/love/get/$pkgver.tar.gz"
builddir="$srcdir"/rude-love-8c6f6a0ca1f0/
options="!check" #No checks

prepare() {
	default_prepare
	platform/unix/automagic
	./configure --prefix=/usr LDFLAGS="$LDFLAGS" lua_CFLAGS="-I/usr/bin/luajit" lua_LIBS="-L/usr/lib -lluajit-5.1"
}

build() {
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="546cafe4cf1d5e0d0cac943d74d62390eef89f9875db892375aee27eee5c93c93841fa6b9726ef5ea1ce76ff98bc918593d18e1c5b55415c7701d5c8c25c4a80  love-11.3.tar.gz"
